package com.ruoyi.guarantee.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.guarantee.mapper.BAgreementCheckMapper;
import com.ruoyi.guarantee.domain.BAgreementCheck;
import com.ruoyi.guarantee.service.IBAgreementCheckService;

/**
 * 履约保函审核日志Service业务层处理
 *
 * @author ruoyi
 * @date 2024-11-06
 */
@Service
public class BAgreementCheckServiceImpl implements IBAgreementCheckService
{
    @Autowired
    private BAgreementCheckMapper bAgreementCheckMapper;

    /**
     * 查询履约保函审核日志
     *
     * @param id 履约保函审核日志主键
     * @return 履约保函审核日志
     */
    @Override
    public BAgreementCheck selectBAgreementCheckById(Long id)
    {
        return bAgreementCheckMapper.selectBAgreementCheckById(id);
    }

    /**
     * 查询履约保函审核日志列表
     *
     * @param bAgreementCheck 履约保函审核日志
     * @return 履约保函审核日志
     */
    @Override
    public List<BAgreementCheck> selectBAgreementCheckList(BAgreementCheck bAgreementCheck)
    {
        return bAgreementCheckMapper.selectBAgreementCheckList(bAgreementCheck);
    }

    /**
     * 新增履约保函审核日志
     *
     * @param bAgreementCheck 履约保函审核日志
     * @return 结果
     */
    @Override
    public int insertBAgreementCheck(BAgreementCheck bAgreementCheck)
    {
        bAgreementCheck.setCreateTime(DateUtils.getNowDate());
        return bAgreementCheckMapper.insertBAgreementCheck(bAgreementCheck);
    }

    /**
     * 修改履约保函审核日志
     *
     * @param bAgreementCheck 履约保函审核日志
     * @return 结果
     */
    @Override
    public int updateBAgreementCheck(BAgreementCheck bAgreementCheck)
    {
        return bAgreementCheckMapper.updateBAgreementCheck(bAgreementCheck);
    }

    /**
     * 批量删除履约保函审核日志
     *
     * @param ids 需要删除的履约保函审核日志主键
     * @return 结果
     */
    @Override
    public int deleteBAgreementCheckByIds(Long[] ids)
    {
        return bAgreementCheckMapper.deleteBAgreementCheckByIds(ids);
    }

    /**
     * 删除履约保函审核日志信息
     *
     * @param id 履约保函审核日志主键
     * @return 结果
     */
    @Override
    public int deleteBAgreementCheckById(Long id)
    {
        return bAgreementCheckMapper.deleteBAgreementCheckById(id);
    }
}
